﻿package Message.Game
{
    import Framework.MQ.*;
    import Framework.Serialize.*;
    import Message.Public.*;

    public class SPlayerInviteInfo extends IMessageBase
    {
        public var mode:int;
        public var guild:SMiniGuildInfo;
        public var inviter:SMiniPlayer;
        public const _type:int = 16115;
        public static var _regist:SPlayerInviteInfo = new SPlayerInviteInfo(true);

        public function SPlayerInviteInfo(param1:Boolean = false)
        {
            if (param1)
            {
                MessageManager.instance().regist(this);
            }
            return;
        }// end function

        override public function getType() : int
        {
            return this._type;
        }// end function

        override public function clone() : IMessageBase
        {
            return new SPlayerInviteInfo();
        }// end function

        override public function __write(param1:SerializeStream) : void
        {
            param1.writeInt(this.mode);
            this.guild.__write(param1);
            this.inviter.__write(param1);
            return;
        }// end function

        override public function __read(param1:SerializeStream) : void
        {
            this.mode = param1.readInt();
            this.guild = new SMiniGuildInfo();
            this.guild.__read(param1);
            this.inviter = new SMiniPlayer();
            this.inviter.__read(param1);
            return;
        }// end function

    }
}
